//
//  ZLTravelsModel.m
//  TripTogether
//
//  Created by dllo on 15/12/29.
//  Copyright © 2015年 杨泓晔. All rights reserved.
//

#import "ZLTravelsModel.h"

@implementation ZLTravelsModel


//必须用下划线  _
-(void)setWaypoints:(NSMutableArray *)waypoints{
    if (_waypoints != waypoints) {
        _waypoints = waypoints;
    }
    NSMutableArray *tempArray = [NSMutableArray array];
    for (NSDictionary *waypointDic in _waypoints) {
        ZLwaypointsModel *sma = [[ZLwaypointsModel alloc] init];
        [sma setValuesForKeysWithDictionary:waypointDic];
        [tempArray addObject:sma];
    }
    _waypoints = [NSMutableArray arrayWithArray:tempArray];
}

//self. 和 下划线  _  都可以用
-(void)setTrip:(NSMutableDictionary *)trip{
    if (_trip != trip) {
        _trip = trip;
    }
    
    self.myTrip = [[ZLTripModel alloc] init];
    [self.myTrip setValuesForKeysWithDictionary:trip];
}



@end
//**********************************
@implementation ZLTripModel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}
-(void)setUser:(NSMutableDictionary *)user{
    
    if (_user != user) {
        _user = user;
    }
    self.fuckM = [[ZLexperienceMOdel alloc]init];
    [self.fuckM setValuesForKeysWithDictionary:user];
}
@end

//-----------------------------------
@implementation ZLexperienceMOdel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}

-(void)setExperience:(NSMutableDictionary *)experience
{
    if (_experience != experience) {
        _experience = experience;
    }
    self.hehe = [[ZLlevel_infoMOdel alloc]init];
    [self.hehe setValuesForKeysWithDictionary:experience];
}

@end


@implementation ZLlevel_infoMOdel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}

-(void)setLevel_info:(NSMutableDictionary *)level_info
{
    if (_level_info != level_info) {
        _level_info = level_info;
    }
    self.papa = [ZLValueModel new];
    [self.papa setValuesForKeysWithDictionary:level_info];
}

@end

@implementation ZLValueModel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}

@end


//>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
@implementation ZLwaypointsModel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}

-(void)setPhoto_info:(NSMutableDictionary *)photo_info
{
    //    NSLog(@"11111111");
    if (_photo_info != photo_info) {
        _photo_info = photo_info;
    }
    self.littleM = [ZLHWMOdel new];
    [self.littleM setValuesForKeysWithDictionary:photo_info];
}
@end

@implementation ZLHWMOdel

-(void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    
}

@end














